//package com.bootdo.util;
//
//
//import com.bootdo.cm.service.CmInvestService;
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.stereotype.Component;
//
//import java.text.SimpleDateFormat;
//import java.util.Date;
//
///**
// * @author 戚云啸
// * @version 1.0
// * @date 2021/2/24 14:46
// * @mail 625997421@qq.com
// * @description 维保单号工具类
// */
//
//@Component
//public class IDUtil {
//
////    @Autowired
////    private HlmUserService hlmUserService;
//
//    @Autowired
//    private CmInvestService cmInvestService;
////    @Autowired
////    private CmResourceService cmResourceService;
//
//
//    /**
//     * 合同编号 0 付款合同 1 首款合同
//     * @return
//     */
////    public String getUserCode(String whetherColl){
////        System.out.println("****************");
////        String prefix = "";
////        if ("0".equals(whetherColl)) {
////            prefix = "RW";
////        }else {
////            prefix = "GX";
////        }
////        String date = new SimpleDateFormat("yyyyMMdd").format(new Date());
////        System.out.println(date);
////        System.out.println("--------------");
////        String id = hlmUserService.getWeibId(date);
////        if (id == null){
////            id=prefix + date+"-01";
////        }else {
////            int n = Integer.parseInt(id);
////            n = n+1;
////            if (n<10){
////                id =prefix+date+"-0" + n;
////            }else {
////                id =prefix+date+"-" + n;
////            }
////        }
////        return id;
////    }
//
//
//    public String getCmInvestCode(){
//        System.out.println("****************");
//        String prefix = "";
//        prefix = "ZS-";
//        String date = new SimpleDateFormat("yyyyMMdd").format(new Date());
//        System.out.println(date);
//        System.out.println("--------------");
//        String id = cmInvestService.getWeibId(date);
//        if (id == null){
//            id=prefix + date+"-01";
//        }else {
//            int n = Integer.parseInt(id);
//            n = n+1;
//            if (n<10){
//                id =prefix+date+"-0" + n;
//            }else {
//                id =prefix+date+"-" + n;
//            }
//        }
//        return id;
//    }
//
//
////    public String getCmResourceCode() {
////        System.out.println("****************");
////        String prefix = "";
////        prefix = "ZY-";
////        String date = new SimpleDateFormat("yyyyMMdd").format(new Date());
////        System.out.println(date);
////        System.out.println("--------------");
////        String id = cmResourceService.getWeibId(date);
////        if (id == null){
////            id=prefix + date+"-01";
////        }else {
////            int n = Integer.parseInt(id);
////            n = n+1;
////            if (n<10){
////                id =prefix+date+"-0" + n;
////            }else {
////                id =prefix+date+"-" + n;
////            }
////        }
////        return id;
////    }
//
//    public String getCmResourceInvestCode() {
//        return null;
//    }
//
//    public String getSysTableRelCode() {
//        return null;
//    }
//}
